package com.pay.domain.po;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * @author ZhouYihe 1552951165@qq.com
 * @create 2024/10/26 14:23
 * @description 商品的支付单表
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@TableName("pay_order")
@ApiModel(value = "PayOrder对象", description = "商品的支付单表")
public class PayOrder implements Serializable {
    private static final long serialVersionUID = 1L;
    
    @ApiModelProperty(value = "自增ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    
    @ApiModelProperty(value = "用户ID")
    private String userId;
    
    @ApiModelProperty(value = "商品ID")
    private String productId;
    
    @ApiModelProperty(value = "商品名称")
    private String productName;
    
    @ApiModelProperty(value = "订单ID")
    private String orderId;
    
    @ApiModelProperty(value = "下单时间")
    private LocalDateTime orderTime;
    
    @ApiModelProperty(value = "订单金额")
    private BigDecimal totalAmount;
    
    @ApiModelProperty(value = "订单状态；create-创建完成、pay_wait-等待支付、pay_success-支付成功、deal_done-交易完成、close-订单关单")
    private String status;
    
    @ApiModelProperty(value = "支付信息")
    private String payUrl;
    
    @ApiModelProperty(value = "支付时间")
    private LocalDateTime payTime;
    
    @ApiModelProperty(value = "创建时间")
    private LocalDateTime createTime;
    
    @ApiModelProperty(value = "更新时间")
    private LocalDateTime updateTime;
    
}
